// default package
// Generated 28 Jul, 2014 8:04:07 PM by Hibernate Tools 3.4.0.CR1
package com.galaxy.bean;

import java.math.BigDecimal;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import static javax.persistence.GenerationType.IDENTITY;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
import javax.persistence.UniqueConstraint;

/**
 * CatalogProductSuperAttributePricing generated by hbm2java
 */
@Entity
@Table(name = "catalog_product_super_attribute_pricing", catalog = "magento", uniqueConstraints = @UniqueConstraint(columnNames = {
		"product_super_attribute_id", "value_index", "website_id" }))
public class CatalogProductSuperAttributePricing implements
		java.io.Serializable {

	private Integer valueId;
	private CoreWebsite coreWebsite;
	private CatalogProductSuperAttribute catalogProductSuperAttribute;
	private String valueIndex;
	private Short isPercent;
	private BigDecimal pricingValue;

	public CatalogProductSuperAttributePricing() {
	}

	public CatalogProductSuperAttributePricing(CoreWebsite coreWebsite,
			CatalogProductSuperAttribute catalogProductSuperAttribute,
			String valueIndex) {
		this.coreWebsite = coreWebsite;
		this.catalogProductSuperAttribute = catalogProductSuperAttribute;
		this.valueIndex = valueIndex;
	}

	public CatalogProductSuperAttributePricing(CoreWebsite coreWebsite,
			CatalogProductSuperAttribute catalogProductSuperAttribute,
			String valueIndex, Short isPercent, BigDecimal pricingValue) {
		this.coreWebsite = coreWebsite;
		this.catalogProductSuperAttribute = catalogProductSuperAttribute;
		this.valueIndex = valueIndex;
		this.isPercent = isPercent;
		this.pricingValue = pricingValue;
	}

	@Id
	@GeneratedValue(strategy = IDENTITY)
	@Column(name = "value_id", unique = true, nullable = false)
	public Integer getValueId() {
		return this.valueId;
	}

	public void setValueId(Integer valueId) {
		this.valueId = valueId;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "website_id", nullable = false)
	public CoreWebsite getCoreWebsite() {
		return this.coreWebsite;
	}

	public void setCoreWebsite(CoreWebsite coreWebsite) {
		this.coreWebsite = coreWebsite;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "product_super_attribute_id", nullable = false)
	public CatalogProductSuperAttribute getCatalogProductSuperAttribute() {
		return this.catalogProductSuperAttribute;
	}

	public void setCatalogProductSuperAttribute(
			CatalogProductSuperAttribute catalogProductSuperAttribute) {
		this.catalogProductSuperAttribute = catalogProductSuperAttribute;
	}

	@Column(name = "value_index", nullable = false)
	public String getValueIndex() {
		return this.valueIndex;
	}

	public void setValueIndex(String valueIndex) {
		this.valueIndex = valueIndex;
	}

	@Column(name = "is_percent")
	public Short getIsPercent() {
		return this.isPercent;
	}

	public void setIsPercent(Short isPercent) {
		this.isPercent = isPercent;
	}

	@Column(name = "pricing_value", precision = 12, scale = 4)
	public BigDecimal getPricingValue() {
		return this.pricingValue;
	}

	public void setPricingValue(BigDecimal pricingValue) {
		this.pricingValue = pricingValue;
	}

}
